<?php
function colorSource($sFileContent, $sFileLanguage){
  include_once SCRIPT_DIR_LOCAL.'/geshi/geshi.php';
  $assExtension = array(
  	'js' => 'javascript',
  	'php' => 'php',
  	'html' => 'hmtl',
  	'xhtml' => 'xhtml',
  	'css' => 'css',
  	'xsl' => 'xsl',
  	'sql' => 'sql',
  	'xml' => 'xml'
  );
  foreach($assExtension as $sExtension => $sLanguage){
  	$sSourceLanguage = str_replace($sExtension, $sLanguage, $sFileLanguage);
  }
  $oGeshiInstance = new GeSHi($sFileContent, $sSourceLanguage);

  return $oGeshiInstance->parse_code();
}